package middleware

import (
	configx "config"

	"github.com/go-kratos/kratos/v2/middleware"
	"github.com/go-kratos/kratos/v2/middleware/auth/jwt"
	jwtv5 "github.com/golang-jwt/jwt/v5"
)

func Jwt() middleware.Middleware {
	return jwt.Server(func(token *jwtv5.Token) (interface{}, error) {
		return []byte(configx.EtcdEndpoints), nil
	})
}
